package com.mingda.weathermagiccenter.pojo;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;
import java.time.LocalDateTime;
import java.util.Date;

import com.sleepycat.persist.model.PrimaryKey;
import lombok.Data;

/**
 * 
 * @TableName ws_alarm_data
 */
@TableName(value ="ws_alarm_data")
@Data
public class WsAlarmData implements Serializable {
    /**
     * 
     */
    @TableId(value = "id")
    @PrimaryKey
    private String id;

    /**
     * 
     */
    @TableField(value = "stationkey")
    private String stationkey;

    /**
     * 
     */
    @TableField(value = "orgid")
    private String orgid;

    /**
     * 
     */
    @TableField(value = "name")
    private String name;

    /**
     * 
     */
    @TableField(value = "content")
    private String content;

    /**
     * 预警发布时间
     */
    @TableField(value = "starttime")
    private LocalDateTime starttime;

    /**
     * 
     */
    @TableField(value = "type")
    private String type;

    /**
     * 
     */
    @TableField(value = "typename")
    private String typename;

    /**
     * 日期字符
     */
    @TableField(value = "fxdate")
    private String fxdate;

    /**
     * 记录插入时间
     */
    @TableField(value = "ctime")
    private LocalDateTime ctime;

    /**
     * 预警信息发布状态
     */
    @TableField(value = "status")
    private String status;

    /**
     * 预警结束时间
     */
    @TableField(value = "endtime")
    private LocalDateTime endtime;

    /**
     * 预警严重等级
     */
    @TableField(value = "severity")
    private String severity;

    /**
     * 预警严重等级颜色
     */
    @TableField(value = "severitycolor")
    private String severitycolor;

    /**
     * 发布单位
     */
    @TableField(value = "sender")
    private String sender;

    /**
     * 
     */
    @TableField(value = "pubtime")
    private LocalDateTime pubtime;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        WsAlarmData other = (WsAlarmData) that;
        return (this.getId() == null ? other.getId() == null : this.getId().equals(other.getId()))
            && (this.getStationkey() == null ? other.getStationkey() == null : this.getStationkey().equals(other.getStationkey()))
            && (this.getOrgid() == null ? other.getOrgid() == null : this.getOrgid().equals(other.getOrgid()))
            && (this.getName() == null ? other.getName() == null : this.getName().equals(other.getName()))
            && (this.getContent() == null ? other.getContent() == null : this.getContent().equals(other.getContent()))
            && (this.getStarttime() == null ? other.getStarttime() == null : this.getStarttime().equals(other.getStarttime()))
            && (this.getType() == null ? other.getType() == null : this.getType().equals(other.getType()))
            && (this.getTypename() == null ? other.getTypename() == null : this.getTypename().equals(other.getTypename()))
            && (this.getFxdate() == null ? other.getFxdate() == null : this.getFxdate().equals(other.getFxdate()))
            && (this.getCtime() == null ? other.getCtime() == null : this.getCtime().equals(other.getCtime()))
            && (this.getStatus() == null ? other.getStatus() == null : this.getStatus().equals(other.getStatus()))
            && (this.getEndtime() == null ? other.getEndtime() == null : this.getEndtime().equals(other.getEndtime()))
            && (this.getSeverity() == null ? other.getSeverity() == null : this.getSeverity().equals(other.getSeverity()))
            && (this.getSeveritycolor() == null ? other.getSeveritycolor() == null : this.getSeveritycolor().equals(other.getSeveritycolor()))
            && (this.getSender() == null ? other.getSender() == null : this.getSender().equals(other.getSender()))
            && (this.getPubtime() == null ? other.getPubtime() == null : this.getPubtime().equals(other.getPubtime()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getId() == null) ? 0 : getId().hashCode());
        result = prime * result + ((getStationkey() == null) ? 0 : getStationkey().hashCode());
        result = prime * result + ((getOrgid() == null) ? 0 : getOrgid().hashCode());
        result = prime * result + ((getName() == null) ? 0 : getName().hashCode());
        result = prime * result + ((getContent() == null) ? 0 : getContent().hashCode());
        result = prime * result + ((getStarttime() == null) ? 0 : getStarttime().hashCode());
        result = prime * result + ((getType() == null) ? 0 : getType().hashCode());
        result = prime * result + ((getTypename() == null) ? 0 : getTypename().hashCode());
        result = prime * result + ((getFxdate() == null) ? 0 : getFxdate().hashCode());
        result = prime * result + ((getCtime() == null) ? 0 : getCtime().hashCode());
        result = prime * result + ((getStatus() == null) ? 0 : getStatus().hashCode());
        result = prime * result + ((getEndtime() == null) ? 0 : getEndtime().hashCode());
        result = prime * result + ((getSeverity() == null) ? 0 : getSeverity().hashCode());
        result = prime * result + ((getSeveritycolor() == null) ? 0 : getSeveritycolor().hashCode());
        result = prime * result + ((getSender() == null) ? 0 : getSender().hashCode());
        result = prime * result + ((getPubtime() == null) ? 0 : getPubtime().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", stationkey=").append(stationkey);
        sb.append(", orgid=").append(orgid);
        sb.append(", name=").append(name);
        sb.append(", content=").append(content);
        sb.append(", starttime=").append(starttime);
        sb.append(", type=").append(type);
        sb.append(", typename=").append(typename);
        sb.append(", fxdate=").append(fxdate);
        sb.append(", ctime=").append(ctime);
        sb.append(", status=").append(status);
        sb.append(", endtime=").append(endtime);
        sb.append(", severity=").append(severity);
        sb.append(", severitycolor=").append(severitycolor);
        sb.append(", sender=").append(sender);
        sb.append(", pubtime=").append(pubtime);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}